package com.jt.spring.demo1;

import com.jt.spring.demo1.config.SpringComfig;
import com.jt.spring.demo1.service.UserService;
import org.springframework.context.ApplicationContext;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;

public class TestTx {
    public static void main(String[] args) {
        ApplicationContext context=
                new AnnotationConfigApplicationContext(SpringComfig.class);
        UserService a = context.getBean(UserService.class);
        a.addUser();

    }

}
